

let buf1 = Buffer.alloc(256);
buf1[0] = 0;
console.log('length:',buf1.length);
console.log('buf1:',buf1);

let i = 1;
for(i; i<buf1.length; i++){
  buf1[i] = i;
}
console.log('buf1',buf1);

let buf2 = Buffer.alloc(10);
buf2 = buf1.slice(246,256);
console.log('buf2.length:' ,buf2.length);
console.log('buf2:',buf2);

buf2.fill(0);
console.log('buf2-0:',buf2);
